package njClass.mvc.core
{
	import flash.events.EventDispatcher;

	public class Command extends EventDispatcher
	{
		public static var CommandsArray:Array=new Array();
		private var Name:String;
		private var app:facade=facade.getInstance();
		
		public function Command(_CommandName:String="")
		{
			Name=_CommandName;
			CommandsArray.push({"NAME":Name});
		}
		
		public function get CommandName():String{
			return Name;
		}
		
		public function StartUp():Boolean{
			return true;
		}
		
		public function sendEvent(EventName:String,Target:Object=null):void{
			app.sendEvent(EventName,Target);
		}
		
		public function initEvent(EventName:String,CommandName:Command,Target:Object=null):void{
			app.initEvent(EventName,CommandName,Target);
		}
	}
}